A HVAC system often uses a compressor to compress the refrigerant. In some cases, the compressor can be driven by an electric motor. The electric motor typically includes a stationary stator and a rotatable rotor. The rotor can be connected to a shaft of the compressor, so that a torque generated by the stator and the rotor can be transmitted from the rotor to the shaft, which can then drive the compressor.